package com.client.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import com.cloud.api.OrderFeign;
import com.cloud.api.UserFeign;
import com.cloud.api.req.OrderReq;
import com.cloud.api.req.UserReq;
import com.cloud.api.resp.UserResp;

@RestController
public class CloudClientController {
	@Autowired
	private UserFeign userFeign;
	
	@Autowired
	private OrderFeign orderFeign;
	@GetMapping("/user/load")
	public UserResp load(UserReq req) {
		return userFeign.load(req);
	}
	
	@GetMapping("/order/save")
	public String save(OrderReq req) {
		return orderFeign.save(req);
	}
}
